package com.anis.project.medcare.editors.table.content.providers;

import java.util.ArrayList;
import java.util.Vector;

import org.eclipse.jface.viewers.IContentProvider;
import org.eclipse.jface.viewers.IStructuredContentProvider;
import org.eclipse.jface.viewers.Viewer;

import com.anis.jpa.medical.model.MedicalReport;
import com.anis.jpa.medical.model.Patient;

public class ReportTableContentProvider implements IStructuredContentProvider {

	@Override
	public void dispose() {
		// TODO Auto-generated method stub

	}

	@Override
	public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {

	}

	@Override
	public Object[] getElements(Object inputElement) {
		if (inputElement instanceof Vector)
			return ((Vector<MedicalReport>) inputElement).toArray();
		else
			return null;
	}

}
